numerical integration by trapezoidal and simpson